/**
 * 
 */
package t4j.innerclasses.controller;

/**
 * @author sz
 *
 * create time：2012-9-25
 */
public abstract class Event {

	private long eventTime;
	
	protected final long delayTime;
	
	public Event(long delayTime){
		this.delayTime = delayTime;
		
	}
	
	public void start(){
		eventTime = System.nanoTime() + delayTime;
		
		
	}
	
	public boolean ready(){
		return System.nanoTime() >= eventTime;
	}
	
	public abstract void action();
}
